<div style="padding: 30px; background-color: #F2F2F2;" class="layui-row layui-col-xs12">
    <div class="layui-card layui-col-xs12 layui-col-sm8 layui-col-md8 layui-col-md-offset2 layui-col-sm-offset2">
        <div class="layui-card-header">购买额度</div>
        <div class="layui-card-body">
            <form class="layui-form layui-form-pane" action="" lay-filter="pay">
                <div class="layui-form-item layui-form-text">
                    <label class="layui-form-label">需购买的额度与时长</label>
                    <div class="layui-input-block">
                        <select name="type" lay-verify="required" lay-reqText="请选择一个额度" lay-verType="tips"
                            id="pay_select">
                            <option value="" selected="">请选择一个额度</option>
                        </select>
                    </div>
                </div>
                <div class="layui-form-item"><label class="layui-form-label">需支付价格</label>
                    <div class="layui-input-block"><input type="text" id="price" class="layui-input"
                            value="请先选择需购买的额度与时长" disabled>
                    </div>
                </div>
                <div class="layui-form-item"><label class="layui-form-label">下单份数</label>
                    <div class="layui-input-block" style="position: relative;">
                        <input type="number" name="num" id="num" class="layui-input" value="1"
                            style="position: absolute;top: 0px;left: 0px;text-align: center;" oninput="input()"
                            autocomplete="off">
                        <button type="button" class="layui-btn layui-btn-default layui-btn-sm"
                            style="position: absolute;top: 0px;left: 0px;height: 100%;" onclick="sub()"><i
                                class="layui-icon">&#xe67e;</i></button>
                        <button type="button" class="layui-btn layui-btn-default layui-btn-sm"
                            style="position: absolute;top: 0px;right: 0px;height: 100%;" onclick="plus()"><i
                                class="layui-icon">&#xe624;</i></button>
                    </div>
                </div>
                <div class="layui-form-item" pane="">
                    <label class="layui-form-label">支付方式</label>
                    <div class="layui-input-block">
                        <input type="radio" name="paytype" value="alipay" title="支付宝" id="radio_alipay">
                        <input type="radio" name="paytype" value="wxpay" title="微信" id="radio_wxpay">
                        <input type="radio" name="paytype" value="qqpay" title="QQ钱包" id="radio_qqpay">
                    </div>
                </div>
                <div class="layui-form-item">
                    <div class="layui-input-block">
                        <div class="layui-col-xs8 layui-col-md6 layui-col-md-offset2"><button type="submit"
                                class="layui-btn layui-btn-default layui-btn-fluid" lay-submit=""
                                lay-filter="pay_button">支付</button>
                        </div>
                    </div>
                </div>
            </form>
        </div>
    </div>
    <div class="layui-card layui-col-xs12 layui-col-sm8 layui-col-md8 layui-col-md-offset2 layui-col-sm-offset2">
        <div class="layui-card-header">小道消息</div>
        <div class="layui-card-body" id="pay_notice">
        </div>
    </div>
    <div class="layui-card layui-col-xs12 layui-col-sm8 layui-col-md8 layui-col-md-offset2 layui-col-sm-offset2">
        <div class="layui-card-header">订单列表</div>
        <div class="layui-card-body">
            <table class="layui-hide" id="order_table" lay-filter="order_table">
            </table>
            <script type="text/html" id="status">
                {{#  if(d.status == 1){ }}
                <font color="green">已支付</font>
                {{#  } else { }}
                <font color="red">未支付</font>
                {{#  } }}
            </script>
        </div>
    </div>
</div>
<script>
    layui.use('pay', layui.factory('pay'));
</script>